package com.yunzhou.controller.user;

import com.yunzhou.result.Result;
import com.yunzhou.service.ForumBoardService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/user/forumBoard")
public class ForumBoardController {

    @Autowired
    private ForumBoardService forumBoardService;

    // 获取一级板块的同时获取所有对应的二级板块
    @GetMapping("/getForumBoard")
    public Result getForumBoard1(){
        return Result.success(forumBoardService.getForumBoard());
    }
}
